package converters;
 
import java.util.Locale;

import org.apache.commons.beanutils.locale.converters.DoubleLocaleConverter;
import org.apache.commons.beanutils.locale.converters.IntegerLocaleConverter;

public class IntegerLocalConverterCustom extends IntegerLocaleConverter {
	public IntegerLocalConverterCustom(Locale locale){
		super(locale);
	}
	public Object convert(Class type, Object value) {
		if(value == null || value.toString().length() < 1)
			return new Integer(0);

		return new Integer(value.toString().replace(',','.'));
	}
}
